-
Notifications
You must be signed in to change notification settings - Fork 4
Statically defining LCD classes, removing post-init checks #21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
I’ll take a look at this as soon as I have some time (not easy this week) |
removed yield functions inside of init, not needed
|
Edit : nice display is good Can you fix the static analysis errors and we can merge that ? https://github.com/Times-Z/GeekMagic-Open-Firmware/actions/runs/21385074066/job/61559824953?pr=21 |
…andler. Removed tft library's init as we are doing our own init anyways
|
From the discussion in #23, turns out that CS is not being driven anyways. So there is not need for a custom SPI handler, the parent class |
|
I planned to try this this in the beginning of the week Nice work !! I didn't find this tricks on my side (since I'm new in the world) |
Times-Z
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for updating doc as well !
|
🎉 This PR is included in version 1.2.0 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |

This PR moves the classes
GeekMagicSPIBusandArduino_ST7789away from dynamically allocated towards statically allocated.There should be no reason to dynamically allocate them nor check for their readiness in run-time: the setup function calls the lcd init function, and from there are initialized throughout the lifecycle of the LCD. The init function itself cannot fail as it just writes to the spi bus.
This PR also enables a 2 second watchdog timer, in case something in
loop()craps out. Needs more testing for this.Also as a side note, why the
yieldcalls insidelcdRunVendorInit? At this stage nothing else should really be running on the MCU that would require preemptive tasking (mainly wifi).